package com.ymatou.img.api.service;

import org.json.JSONObject;

import com.ymt.base.YmatouBaseCall;
import com.ymttest.utils.EnvSetup;

/**
 * 上传图片Call FreeMaker Template自动生成代码
 */
public class ConfirmCall extends YmatouBaseCall {
	private static String opurl = "api/Image/Confirm";

	public ConfirmCall() {
		super(EnvSetup.getSystemUrl("img_iapi"), opurl, "GET", "PARAM");
	}
	/**
	 * "GET", "PARAM"
	 * @param addurl
	 * @param type
	 */
	public ConfirmCall(String addurl) {
		super(EnvSetup.getSystemUrl("img_iapi"), opurl+addurl, "GET", "PARAM");
	}
	// 上传文件不能加默认头信息
	@Override
	public void addDefHeader() {
	}
	/**
	 * 获取Status
	 * 
	 * @return
	 */
	public String getStatus() {
		String Status = null;
		try {
			Status = new JSONObject(getReturnData()).getString("Status");
		} catch (Exception e) {
			e.printStackTrace();
		}
		return Status;
	}

}